home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Dr. Windows 3
/
dr win3.zip
/
dr win3
/
WINSYSTM
/
WMB009A1.ZIP
/
WW0654.TX_
/
WW0654.TXT
Wrap
Text File
|
1993-02-22
|
45KB
|
1,063 lines
======================================================================
Microsoft(R) Product Support Services Application Note (Text File)
WW0654: WINDOWS 3.1 AND SERIAL COMMUNICATIONS
======================================================================
Revision Date: 2/93
No Disk Included
The following information applies to Microsoft Windows(TM) version
3.1.
--------------------------------------------------------------------
| INFORMATION PROVIDED IN THIS DOCUMENT AND ANY SOFTWARE THAT MAY |
| ACCOMPANY THIS DOCUMENT (collectively referred to as an |
| Application Note) IS PROVIDED "AS IS" WITHOUT WARRANTY OF ANY |
| KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO |
| THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A |
| PARTICULAR PURPOSE. The user assumes the entire risk as to the |
| accuracy and the use of this Application Note. This Application |
| Note may be copied and distributed subject to the following |
| conditions: 1) All text must be copied without modification and |
| all pages must be included; 2) If software is included, all files |
| on the disk(s) must be copied without modification [the MS-DOS(R) |
| utility DISKCOPY is appropriate for this purpose]; 3) All |
| components of this Application Note must be distributed together; |
| and 4) This Application Note may not be distributed for profit. |
| |
| Copyright 1992 Microsoft Corporation. All Rights Reserved. |
| Microsoft and MS-DOS are registered trademarks and Windows |
| is a trademark of Microsoft Corporation. |
| IBM, Micro Channel, and PS/2 are registered trademarks of |
| International Business Machines Corporation. |
| Logitech is a trademark of Logitech, Inc. |
--------------------------------------------------------------------
INTRODUCTION
============
This application note provides information about serial communications
in the Microsoft Windows version 3.1 operating system environment. The
first section, "What's New in Windows Version 3.1," gives an overview
of improvements in Windows 3.1. The section "Conceptual Overview"
explains basic and advanced concepts in serial communications,
including port addresses, device contention, and so forth. The section
"Why Conflicts Occur" discusses the most common reasons why you may
experience difficulties with serial communications, and the section
"How to Resolve Conflicts" explains what to do once you have
identified the problem.
If you need help with a specific problem, you may want to start by
reading the "Troubleshooting" section.
WHAT'S NEW IN WINDOWS VERSION 3.1
=================================
Here are some highlights about improvements in how Windows 3.1 handles
serial communications.
Performance Improvements
------------------------
- Windows 3.1 supports the high-speed 16550AFN UART buffer; Windows
3.0 does not. (The 16550AFN buffer is supported for Windows-based
applications only.)
- Windows 3.1 supports baud rates of up to 57.6K. (You may need to
update your application to take advantage of these higher baud
rates.) Some users experienced lockups during high-speed, full-
duplex transfers while using Windows 3.0. These problems are
resolved in Windows 3.1.
- Windows 3.1 has a new serial driver interface that allows data to
be passed in blocks, instead of one character at a time. (Each
block is treated as a single character.) This means faster data
throughput and fewer transmission errors. Windows 3.0 passes data
one character at a time.
- Windows 3.0 uses a "constant polling" method to determine when
serial ports are occupied. Windows 3.1 uses the
EnableCommNotification API; this enables applications to directly
notify Windows of serial events, thereby increasing overall system
performance.
Better Support for Your Ports
-----------------------------
- Windows 3.1 provides better support for COM ports 3 and 4. You can
now configure these ports by using Windows Control Panel.
- Windows 3.1 fully supports IRQ sharing; Windows 3.0 does not. (To
take advantage of this feature, your PC must have Extended Industry
Standard Architecture (EISA) or Micro Channel(R) Architecture
(MCA), or you must have a serial I/O card that supports IRQ
sharing.)
CONCEPTUAL OVERVIEW
===================
This section provides a general introduction to the subject of serial
communications and explains many of the concepts and issues that are
discussed throughout the "Windows 3.1 and Serial Communications"
application note.
SERIAL VS. PARALLEL PORTS
=========================
Input/output (I/O) ports provide the means for your PC to send or
receive data through external devices such as modems, printers, fax
machines, and so forth. Virtually all PCs have both parallel and
serial ports. There are several distinctions between serial and
parallel I/O ports.
Parallel ports are generally used only for printers, which is where
the name LPT, for line printer, originates. Parallel ports transmit
data in complete bytes, and in most cases they handle outgoing data
only; they cannot receive information. (The IBM[R] PS/2[R] parallel
ports are bidirectional; in addition, you can use certain peripherals,
such as network card adapters, to enable your ports to transmit data
bidirectionally.) You do not configure parallel ports; they are
preconfigured for your machine.
Serial ports are generally used for communications, or COM devices,
which include serial printers, modems, fax machines, and so forth.
Serial ports are capable of both sending and receiving data. You can
configure settings--such as parity, stop bits, and data length--for
your serial ports. (In Windows, you can specify these settings by
using Control Panel.) Serial ports transmit data one bit at a time,
sequentially (or serially).
PORT ADDRESSES AND IRQS
=======================
Every time you start your PC, your system BIOS checks your COM ports
to see what serial devices are installed on your PC and posts this
information to the system BIOS data area (BDA). Windows "reads" the
BDA, and uses the default interrupt request line (IRQ) for each device
that is registered there. Usually, each COM port requires a unique IRQ
to communicate with your PC. Certain PCs and some I/O cards support
IRQ sharing.
NOTE: Some earlier BIOS versions may not check for devices on COM
ports 3 and 4. If you have devices installed on COM port 3 or 4 and
your system BIOS does not recognize these ports, you need to
register the addresses for COM3 and COM4 by using Windows Control
Panel. This is explained in the procedure "To register a serial
device" later in this application note.
How Should My COM Ports Be Configured?
--------------------------------------
Generally, PCs come with built-in ports COM1 and COM2 preset to the
following values:
Port Address IRQ
----------------------------
COM1 03F8 4
COM2 02F8 3
In most cases, the default values for COM ports 1 and 2 should work
for your system. You can view your COM port settings by using Windows
Control Panel.
Most PCs do not have built-in ports for COM3 and COM4. The default
settings for these additional ports are listed here:
Port Address IRQ
------------------------------------
COM3 03E8 4
COM3 (PS/2) 3220 3
COM4 02E8 3
Because COM1 and COM3 both use IRQ4 as the def